package com.scitc.flutter_pleasure_video


import io.flutter.embedding.android.FlutterActivity
import io.flutter.embedding.engine.FlutterEngine
import io.flutter.embedding.engine.plugins.shim.ShimPluginRegistry
import io.flutter.plugin.common.PluginRegistry
import io.flutter.plugins.GeneratedPluginRegistrant

class MainActivity: FlutterActivity() {

    override fun configureFlutterEngine(flutterEngine:FlutterEngine){
        GeneratedPluginRegistrant.registerWith(flutterEngine)
        val shimPluginRegistry = ShimPluginRegistry(flutterEngine)
        registerCustomPlugin(shimPluginRegistry)
    }


    private fun registerCustomPlugin(registrar: PluginRegistry){
        ToastUtilPlugin.registerWith(registrar.registrarFor(ToastUtilPlugin.toastChannel));
    }
}
